var domain = 'munpia.com';
var url = 'http://www.munpia.com/list_fav3.php';
var new_indexer = 'image/fav/new.gif';

function isLogin(text) {
	if(text.indexOf('id="fav_help"') == -1)
		return true;
	else
		return false;
}

function getNewArticleBadge(text) {
	if(!isLogin(text))
		return "-";

	var count = 0;
	var index = text.indexOf(new_indexer);
	while(index != -1) {
		text = text.substring(index+1);
		index = text.indexOf(new_indexer);
		count++;
	}	
	return count.toString();
}

